<?php


namespace app\order\admin;


use app\admin\controller\Admin;
use app\common\builder\ZBuilder;
use think\Db;

class Index extends Admin
{

    /**
     * @return mixed
     * @throws \think\Exception
     */
    public function index(){
        return ZBuilder::make('table')
            ->hideCheckbox()
            ->addColumns([
                ['id','订单ID'],
                ['goods_name','商品名称'],
                ['order_price','价格'],
                ['pay_name','支付方式'],
                ['created_at','创建时间'],

                ['pay_time','支付时间','callback',function($val){return date('Y-m-d H:i:s',$val);}],
            ])

            ->fetch();

    }

}